package com.threeox.commonlibrary.entity;

import java.util.UUID;

import com.threeox.commonlibrary.entity.base.BaseObj;
import com.threeox.ormlibrary.annotation.create.Column;
import com.threeox.ormlibrary.annotation.create.Table;

/**
 *
 * @ClassName: JSONStoreMsg
 *
 * @Description: Todo(JSON数据的存储仓库)
 *
 * @author 赵屈犇
 *
 * @date 创建时间:2016/12/20 17:37
 *
 * @version 1.0
 */
@Table
public class JSONStoreMsg extends BaseObj {

	public static final String TABLENAME = "JSONStoreMsg";

	@Column(isPrimary = true , isUnique = true , isNotNull = true)
	private String objectGUID;
	@Column
	private String parentGUID;
	@Column
	private String modelName;
	@Column
	private String jsonContent;
	@Column(defaultVal = "0")
	private Integer state;
	@Column
	private long createTime;
	@Column
	private String userId;

	public JSONStoreMsg(String parentGUID, String modelName,
			String jsonContent, String userId) {
		super();
		this.objectGUID = UUID.randomUUID().toString();
		this.parentGUID = parentGUID;
		this.modelName = modelName;
		this.jsonContent = jsonContent;
		this.createTime = System.currentTimeMillis();
		this.userId = userId;
	}

	public JSONStoreMsg() {
		super();
	}

	public String getObjectGUID() {
		return objectGUID;
	}

	public void setObjectGUID(String objectGUID) {
		this.objectGUID = objectGUID;
	}

	public String getParentGUID() {
		return parentGUID;
	}

	public void setParentGUID(String parentGUID) {
		this.parentGUID = parentGUID;
	}

	public String getModelName() {
		return modelName;
	}

	public void setModelName(String modelName) {
		this.modelName = modelName;
	}

	public String getJsonContent() {
		return jsonContent;
	}

	public void setJsonContent(String jsonContent) {
		this.jsonContent = jsonContent;
	}

	public Integer getState() {
		return state;
	}

	public void setState(Integer state) {
		this.state = state;
	}

	public long getCreateTime() {
		return createTime;
	}

	public void setCreateTime(long createTime) {
		this.createTime = createTime;
	}

	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = userId;
	}

}
